package com.xg.controller;

import com.xg.service.VerificationCodeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RequestMapping("/verificationCode")
@RestController
public class VerificationCodeController {

    @Autowired
    private VerificationCodeService verificationCodeService;

    /**
     * 发送验证码
     */
    @RequestMapping("/sendCode")
    public String sendCode(@RequestParam("userPhone") String userPhone){

        return verificationCodeService.sendCode(userPhone);

    }

}
